<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:c="http://java.sun.com/jsp/jstl/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:g="http://giava.by/common/base"
	template="/WEB-INF/layout/t.xhtml">

	<ui:define name="title">
		<h:outputText value="Scheda Partecipante" />
	</ui:define>
	<ui:define name="roles">
		<f:attribute name="roles" value="exhibition" />
	</ui:define>

	<ui:define name="content">
		<center>
			<p:panel header="Gestione Partecipante">
				<h:panelGrid columns="2" style="width: 95%">

					<h:outputLabel for="exhibition" value="Esposizione:"
						style="width: 100%;" />
					<h:outputText id="exhibition"
						value="#{participantController.element.exhibition.name}"
						style="width: 100%;" />
					<h:outputLabel for="subject" value="Soggetto:" style="width: 100%;" />
					<h:outputText id="subject"
						value="#{participantController.element.subject.name} #{participantController.element.subject.surname}"
						style="width: 100%;" />
					<h:outputLabel for="description" value="Descrizione:"
						style="width: 100%;" />
					<h:outputText id="description"
						value="#{participantController.element.description}"
						escape="false" style="width: 100%;" />

					<h:outputLabel for="phone" value="Telefono: " style="width: 100%;" />
					<h:outputText id="phone"
						value="#{participantController.element.phone}"
						style="width: 100%;" />

					<h:outputLabel for="email" value="Email: " style="width: 100%;" />
					<h:outputText id="email"
						value="#{participantController.element.email}"
						style="width: 100%;" />

					<h:outputLabel for="oeuvreTitle" value="Titolo opera: "
						style="width: 100%;" />
					<h:outputText id="oeuvreTitle"
						value="#{participantController.element.oeuvreTitle}"
						style="width: 100%;" />

					<h:outputLabel for="dimensions" value="Dimensioni: "
						style="width: 100%;" />
					<h:outputText id="dimensions"
						value="#{participantController.element.dimensions}"
						style="width: 100%;" />

					<h:outputLabel for="material" value="Materiale e tecnica: "
						style="width: 100%;" />
					<h:outputText id="material"
						value="#{participantController.element.material}"
						style="width: 100%;" />

					<h:outputLabel for="summary" value="summary: " style="width: 100%;" />
					<h:outputText id="summary"
						value="#{participantController.element.summary}"
						style="width: 100%;" />

					<h:outputLabel for="discipline" value="Disciplina: "
						style="width: 100%;" />
					<h:outputText id="discipline"
						value="#{participantController.element.discipline.name}"
						style="width: 100%;" />

					<h:outputLabel for="participationType"
						value="Tipo Partecipazione: " style="width: 100%;" />
					<h:outputText id="participationType"
						value="#{participantController.element.participationType}"
						style="width: 100%;" />

					<h:outputLabel for="webSite" value="Sito web: "
						style="width: 100%;" />
					<h:outputText id="webSite"
						value="#{participantController.element.webSite}"
						style="width: 100%;" />

					<h:outputLabel for="facebookAccount" value="Account Facebook: "
						style="width: 100%;" />
					<h:outputText id="facebookAccount"
						value="#{participantController.element.facebookAccount}"
						style="width: 100%;" />

					<h:outputLabel for="twitterAccount" value="Account Twitter: "
						style="width: 100%;" />
					<h:outputText id="twitterAccount"
						value="#{participantController.element.twitterAccount}"
						style="width: 100%;" />

					<h:outputLabel for="instagramAccount" value="Account Instagram: "
						style="width: 100%;" />
					<h:outputText id="instagramAccount"
						value="#{participantController.element.instagramAccount}"
						style="width: 100%;" />

					<h:outputLabel for="externalImage" value="External Image: "
						style="width: 100%;" />
					<h:graphicImage id="externalImage"
						value="#{participantController.element.externalImage}"
						alt="#{participantController.element.externalImage}"
						title="#{participantController.element.externalImage}"
						style="padding: 5px;"
						rendered="#{not empty participantController.element.externalImage}" />

					<h:outputLabel for="date" value="Data: " style="width: 100%;" />
					<h:outputText id="date"
						value="#{participantController.element.date}" style="width: 100%;" />

					<h:outputLabel value="Immagine:" for="image"
						rendered="#{not empty participantController.element.image}" />
					<h:graphicImage id="image"
						value="/img/#{participantController.element.image.filename}"
						alt="#{participantController.element.image.filename}"
						title="#{participantController.element.image.filename}"
						style="padding: 5px;"
						rendered="#{not empty participantController.element.image}" />
				</h:panelGrid>
				<br />
			</p:panel>
			<br /> <br />
			<h:panelGrid columns="3">
				<h:form>
					<h:commandButton action="#{participantController.modCurrent}"
						value="Modifica Testi" />
					<h:commandButton action="#{participantController.modImageCurrent}"
						value="Modifica Immagine" />
					<h:commandButton id="addElement"
						action="#{participantController.addElement}" value="Aggiungi" />
				</h:form>
			</h:panelGrid>
		</center>

	</ui:define>
</ui:composition>